#!/usr/bin/python
# server.py
# Copyright (C) Vincenzo Tilotta 2011 <tailot@gmail.com>
#
# util.py is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# util.py is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.

# You should have received a copy of the GNU General Public License along
# with this program.  If not, see <http://www.gnu.org/licenses/>.
def fread(fileopen):
	fd = open(fileopen,"r")
	content = fd.read()
	fd.close()
	return content
def fput(fileopen, content):
	fd = open(fileopen,"wt")
	fd.write(content)
	fd.close()
def isnumeric(mystring):
	try:
  		i = float(mystring)
	except ValueError, TypeError:
		return False
	else:
		return True
